  //Sunday
  StartCountDown("animeth01-1","12/22/2013 08:30 AM +0900","12")
  StartCountDown("animeth01-2","12/22/2013 05:00 PM +0900","12")
  StartCountDown("animeth01-3","12/22/2013 05:30 PM +0900","12")
  StartCountDown("animeth01-4","12/22/2013 08:30 PM +0900","12")
  StartCountDown("animeth01-5","12/29/2013 10:27 PM +0900","13")
  StartCountDown("animeth01-6","12/29/2013 11:30 PM +0900","13")
  StartCountDown("animeth01-7","12/23/2013 00:00 AM +0900","12")
  StartCountDown("animeth01-8","12/23/2013 00:30 AM +0900","12")
  StartCountDown("animeth01-9","12/23/2013 01:05 AM +0900","12")
  //Monday
  StartCountDown("animeth02-1","12/23/2013 06:00 PM +0900","12")
  StartCountDown("animeth02-2","12/23/2013 08:30 PM +0900","12")
  StartCountDown("animeth02-3","12/9/2013 11:30 PM +0900","13")
  StartCountDown("animeth02-4","12/24/2013 01:35 AM +0900","12")
  StartCountDown("animeth02-5","12/24/2013 02:05 AM +0900","12")
  StartCountDown("animeth02-6","12/24/2013 02:55 AM +0900","12")
  //Tue
  StartCountDown("animeth03-1","12/25/2013 00:30 AM +0900","12")
  StartCountDown("animeth03-2","12/25/2013 01:30 AM +0900","12")
  StartCountDown("animeth03-3","12/18/2013 01:35 AM +0900","12")
  //Wed
  StartCountDown("animeth04-1","12/18/2013 09:00 PM +0900","12")
  StartCountDown("animeth04-2","12/19/2013 00:30 AM +0900","12")
  StartCountDown("animeth04-3","12/19/2013 01:30 AM +0900","11")
  StartCountDown("animeth04-4","12/12/2013 01:00 AM +0900","10")
  //Thu
  StartCountDown("animeth05-1","12/19/2013 10:00 PM +0900","12")
  StartCountDown("animeth05-2","12/27/2013 00:50 AM +0900","12")
  StartCountDown("animeth05-3","12/27/2013 01:20 AM +0900","12")
  StartCountDown("animeth05-4","12/20/2013 01:28 AM +0900","12")
  StartCountDown("animeth05-5","12/27/2013 01:35 AM +0900","12")
  StartCountDown("animeth05-6","12/20/2013 01:58 AM +0900","12")
  StartCountDown("animeth05-7","12/20/2013 02:05 AM +0900","12")
  StartCountDown("animeth05-8","12/20/2013 02:35 AM +0900","12")
  //Fri
  StartCountDown("animeth06-1","12/20/2013 09:00 PM +0900","12")
  StartCountDown("animeth06-2","12/20/2013 11:30 PM +0900","12")
  StartCountDown("animeth06-3","12/21/2013 01:30 AM +0900","12")
  StartCountDown("animeth06-4","12/7/2013 01:53 AM +0900","13")
  //Sat
  StartCountDown("animeth07-1","12/21/2013 05:30 PM +0900","12")
  StartCountDown("animeth07-2","12/21/2013 08:30 PM +0900","12")
  StartCountDown("animeth07-3","12/22/2013 01:30 AM +0900","12")
  StartCountDown("animeth07-4","12/22/2013 01:35 AM +0900","12")
  StartCountDown("animeth07-5","12/22/2013 01:58 AM +0900","12")
  StartCountDown("animeth07-6","12/22/2013 02:20 AM +0900","12")
  StartCountDown("animeth07-7","12/29/2013 00:00 AM +0900","26")


  /*
  	Author:		Robert Hashemian (http://www.hashemian.com/)
  */
  
function StartCountDown(myDiv,myTargetDate,epnum)
  {
    var ep = new Number(epnum);
    var dthen	= new Date(myTargetDate);
    var dnow	= new Date();
    ddiff		= new Date(dthen-dnow);
    gsecs		= Math.floor(ddiff.valueOf()/1000);
    CountBack(myDiv,gsecs,ep);
  }
  
  function Calcage(secs, num1, num2)
  {
    s = ((Math.floor(secs/num1))%num2).toString();
    if (s.length < 2) 
    {	
      s = "0" + s;
    }
    return (s);
  }
  function Calchour(epi,secs, num1, num2)
	
   {
    s = ((Math.floor(secs/num1))%num2).toString();
		if ((epi-((Math.floor((secs/num1)/7))%num2)) < 1)
	 {
	 s = s - 77;
	 return (s);
	 }
		if (s < 7)
		 {
		return (s);
		 }
	do 
	{
	s = (s - 7);
	}
	while (s >= 7);
    return (s);
  }


function CalcEp(epi,secs, num1, num2)
	
   {
    s = (epi-((Math.floor((secs/num1)/7))%num2)).toString();
    if (s < 1)
		{
		s = (1);
		}
		return (s);
  }
	 
  
  function CountBack(myDiv, secs,epi)
  {
    var DisplayStr;
    var DisplayFormat = "EP%%E%% \xa0 %%D%%d %%H%%:%%M%%:%%S%%";
    DisplayStr = DisplayFormat.replace((/%%D%%/g),	Calchour(epi,secs,86400,100000));
    DisplayStr = DisplayStr.replace(/%%E%%/g,	            CalcEp(epi,secs,86400,100000));
    DisplayStr = DisplayStr.replace(/%%H%%/g,		Calcage(secs,3600,24));
    DisplayStr = DisplayStr.replace(/%%M%%/g,	Calcage(secs,60,60));
    DisplayStr = DisplayStr.replace(/%%S%%/g,		Calcage(secs,1,60));
    if(secs > 0)
    {	
	  document.getElementById(myDiv).innerHTML = DisplayStr;
      setTimeout("CountBack('" + myDiv + "'," + (secs-1) + ","+ epi +");", 990);
    }
    else
    {
      document.getElementById(myDiv).innerHTML = "   END   ";
    }
  }
